package org.aspect.listener;

import org.aspect.entity.event.SystemLogEvent;
import org.springframework.context.event.EventListener;
import org.springframework.scheduling.annotation.Async;
import org.springframework.stereotype.Component;

/**
 * 日志监听器类
 *
 * @author LiKun
 * @date 2021/10/18 15:46
 */
@Component
public class SystemLogListener {
    @Async
    @EventListener(SystemLogEvent.class)
    public void recordLog(SystemLogEvent systemLogEvent) {
        System.out.println("监听数据为：" + systemLogEvent.toString());
    }
}
